<div class="v-pic-box">
  <?php if($pics){?>
  <div class="v-pic"><img id="goods-img" height="100%" src="<?php echo url::g('u=cimg\b&f='. urlencode($pics[0]))?>" /></div>
  <div class="v-pics" id="goods_imgs"><?php foreach($pics as $v)echo '<img height="60" src="'. url::g('u=cimg\b&f='. urlencode($v)) .'" />';?></div>  
  <?php }?>
</div>

<div class="v-info">
  <h1><?php e_h($data['title'])?></h1>
  <div class="des"><?php e_h($data['description'])?></div>
  <form id="buy_cartpost">
  <dl class="has-cl attr">
    <dt>价格</dt>
    <dd class="price"><?php echo $data['money']?></dd>
    
    <?php if($data['money_old']>0){?>
    <dt>市场价格</dt>
    <dd><s><?php echo $data['money_old']?></s></dd>
    <?php } if($attr_sel_R)foreach($attr_sel_R as $v){
		
	 }?>
    
    <dt>数量</dt>
    <dd><input type="number" value="1" id="goods_num" name="num" /> (剩下<?php echo $data['num']?>件)<input type="hidden" name="data_id" value="<?php echo $data['id']?>" /></dd>
  </dl>
  </form>
  <div class="other-btn-box"><a id="btn_fav_goods" class="btn-fav">收藏</a><a id="btn_add_buy_g">加入购物车</a><button id="btn_buy_goods" class="submit">立即购买</button></div>
  
</div>


<div class="v-content tabB">
 <ul class="tabTitleB">
 	<li class="tab-t">商品信息</li>
 	<li class="tab-t"><a name="tab-1" href="#tab-1">评价<span id="comment_num"></span></a></li></ul>
 <div class="tab-c tabContent">
   <ul class="v-attr-li">
   <?php 
    if($data['company_name'])echo '<li><em>品牌</em>'. htmlq($data['company_name'],null) .'</li>';
    
    if($attrR)foreach($attrR as $v){
		echo '<li><em>'. htmlq($v['name'], null) .'</em>'. htmlq($v['value'],null) .'</li>';
	 }?>
  
  </ul>
  <?php echo $data['content']?>
 </div>
 <div class="tab-c tabContent"><?php $this->loadTemplate('goods/comment/li');?></div>
</div>


<script src="<?php echo JS_PATH?>tf-goods.js"></script>
<script>
$('.paging').find('a').each(function(index, element) {
   this.href += '#tab-1'; 
});
<?php if($n =$this->db->paging['num']) echo '$("#comment_num").text("（'.$n.'）")';?>;
</script>
<style>.paging{ text-align:right; padding-right:12px}</style>